#ifndef KSECURITYLEVELBAR_H
#define KSECURITYLEVELBAR_H

#include "../screencapsdk_global.h"
#include <QWidget>

namespace kdk
{

/** @defgroup MessageAlertModule
  * @{
  */

/**
 * @brief 分为三个安全等级
 */
enum SecurityLevel
{
    Low,
    Medium,
    High
};

class KSecurityLevelBarPrivate;

/**
 * @brief 密码安全等级提示条，支持三个安全等级
 */
class SCREENCAPSDK_EXPORT KSecurityLevelBar : public QWidget
{
    Q_OBJECT
public:
    explicit KSecurityLevelBar(QWidget *parent = nullptr);

    /**
     * @brief 设置安全等级
     * @param level
     */
    void setSecurityLevel(SecurityLevel level);

    /**
     * @brief 获取安全等级
     * @return
     */
    SecurityLevel securityLevel();

protected:
    void paintEvent(QPaintEvent* event);

private:
    Q_DECLARE_PRIVATE(KSecurityLevelBar)
    KSecurityLevelBarPrivate*const d_ptr;
};
}
/**
  * @example testsecuritylevelbar/widget.h
  * @example testsecuritylevelbar/widget.cpp
  * @}
  */

#endif // KSECURITYLEVELBAR_H
